package com.asm.entity.sys;

import com.asm.entity.BaseEntity;
import lombok.Data;
import lombok.experimental.Accessors;
import lombok.extern.slf4j.Slf4j;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.util.Date;

/**
 * @author zhangyufu
 * @description 预定信息类，继承于BaseEntity类
 * 包括销售人员id，工人id，消费者id，合同id
 * @date 2019/7/9
 */
@Slf4j
@Data
@Accessors(chain = true)
@Entity
@Table(name = "t_book")
public class Book extends BaseEntity {

    /**
     * 销售人员id
     */
    @Column(name = "sell_id")
    private Long sellId;

    /**
     * 顾客id
     */
    @Column(name = "customer_id")
    private Long customerId;

    /**
     * 广告位id
     */
    @Column(name = "spot_id")
    private Long spotId;

    @Column(name = "work_order_id")
    private Long workOrderId;

    /**
     * 与预定信息相关的合同编号
     */
    @Column(name = "contract_id")
    private Long contractId;

    /**
     * 预定信息的状态，共有五种：待审核、待派发、待安装、安装完成、未通过
     */
    @Column(name = "status")
    private String status;

    /**
     * 预定日期的开始时间
     */
    @Column(name = "startDate")
    private Date startDate;

    /**
     * 预定日期的结束时间
     */
    @Column(name = "endDate")
    private Date endDate;

}
